package com.zhu.edu.mapper;

import com.zhu.edu.entity.Course;
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author zjc
 * @since 2021-12-21
 */
@Mapper
public interface CourseMapper extends BaseMapper<Course> {
    List<Course> selectThisCourse(Integer userId);

    // 选课结果
    List<Course> selectChooseResult(Integer userId);

    // 历史课程
    List<Course> getHistoryCourse(Integer userId);

    // 本学期成绩
    List<Course> getThisCoursesHasGrade(Integer userId);

    List<Course> getHistoryGrade(Integer userId, Integer term);

    List<Course> getHistoryStartCourses(Integer userId, Integer term);

    List<Course> getThisStartCourses(Integer userId);

    List<Course> getAllStartCourses(Integer schoolId, Integer term);

    int getCourseStatus(Integer courseId);
}
